package com.lanou.horo.zhuizhui.activity;

import android.content.Intent;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.view.View;
import android.widget.Button;
import android.widget.ImageView;

import com.lanou.horo.zhuizhui.R;

/**
 * Created by dllo on 15/10/27.
 */
public class SettingActivity extends AppCompatActivity implements View.OnClickListener {
    private ImageView back;
    private Button readSet, NoticeSet, Concealset, NightSet, FeedbackSet, JoinSet, checkUpdate,
            WifiSet, ScanSet, ModifyIndex, ClearSet, startWizard, disclaimerSet, aboutPrep;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_setting);
        initView();
    }

    private void initView() {
        back = (ImageView) findViewById(R.id.settingBackBtn);
        back.setOnClickListener(this);
        readSet = (Button) findViewById(R.id.readSet);
        readSet.setOnClickListener(this);
        NoticeSet = (Button) findViewById(R.id.NoticeSet);
        NoticeSet.setOnClickListener(this);
        disclaimerSet = (Button) findViewById(R.id.disclaimerSet);
        disclaimerSet.setOnClickListener(this);
        aboutPrep = (Button) findViewById(R.id.aboutPrep);
        aboutPrep.setOnClickListener(this);
    }


    @Override
    public void onClick(View v) {
        switch (v.getId()) {
            case R.id.settingBackBtn:
                finish();
                break;
            case R.id.readSet:
                Intent readSetIntent = new Intent();
                readSetIntent.setClass(this, ReadSettingActivity.class);
                startActivity(readSetIntent);
                break;
            case R.id.NoticeSet:
                Intent NoticeSetIntent = new Intent();
                NoticeSetIntent.setClass(this, NoticeSettingActivity.class);
                startActivity(NoticeSetIntent);
                break;
            case R.id.disclaimerSet:
                Intent disclaimerSetIntent = new Intent();
                disclaimerSetIntent.setClass(this, DisclaimerActivity.class);
                startActivity(disclaimerSetIntent);
                break;
            case R.id.aboutPrep:
                Intent aboutPrepIntent = new Intent(this, AboutPrepActivity.class);
                startActivity(aboutPrepIntent);
                break;
        }
    }
}
